﻿using System;
using System.Data.Linq.Mapping;
using System.Data.SQLite;
using DbLinq.Data.Linq.Mapping;
using DbLinq.Sqlite;
using System.Data.SQLite;

namespace MaternityHospitalPatients.Data
{
    public class ConnectionFactory
    {
        private static readonly SQLiteConnection _connection =
            new SQLiteConnection(string.Format("Data Source={0}\\patient.s3db;Version=3;",
                                               Environment.CurrentDirectory));

        public static Main GetNewConnection()
        {
            return new Main(_connection, new SqliteVendor());
        }
    }
}